﻿using System;
using System.Collections.Generic;
using System.Text;

namespace CO2FixCalibration
{
    static class ArrayOperations
    {
        public static double Multiplicated(double[] a)
        {
            double L = 1;
            foreach (double d in a)
            {
                L *= d;
            }
            return L;
        }

        public static double Average(double[] a)
        {

            return Sum(a) / (float)a.Length;
        }
        public static double Sum(double[] a)
        {
            double sum = 0.0;
            foreach (double d in a)
            {
                sum += d;
            }
            return sum;
        }
    }
}
